import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.io.File;
import java.io.FileWriter;
import java.io.IOException;

public class Add implements ActionListener {
	public Arquivos arq = new Arquivos();
	public Dir dir = new Dir();
	public void actionPerformed (ActionEvent e){
		File caminho = arq.pegarArquivo();
    	try {
			FileWriter writer = new FileWriter("Arquivo.txt",true);
			writer.write(caminho.getPath() +"\n");
			writer.close();
			
		} catch (IOException e1) {
			e1.printStackTrace();
		} 
		}
}
